package cn.gson.springboot.model.pojos;

import java.io.Serializable;
import javax.persistence.*;

import net.sf.jsqlparser.expression.DateTimeLiteralExpression.DateTime;

import java.sql.Time;
import java.sql.Timestamp;
import java.util.List;


/**
 * The persistent class for the operation_record database table.
 * 
 */
@Entity
@Table(name="operation_record")
@NamedQuery(name="OperationRecord.findAll", query="SELECT o FROM OperationRecord o")
public class OperationRecord implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	@Column(name="operation_record_id")
	private int operationRecordId;

	@Column(name="death_time")
	private Timestamp deathTime;

	@Column(name="operation_record_diagnose")
	private String operationRecordDiagnose;

	@Column(name="operation_record_end_time")
	private Time operation_end_time;
	
	@Column(name="operation_record_start_time")
	private Timestamp operation_start_time;

	@Column(name="operation_record_state")
	private String operationRecordState;

	@ManyToOne
	@JoinColumn(name="operation_id")
	private Operation operation;

	//bi-directional many-to-one association to Hospital
	@ManyToOne
	@JoinColumn(name="hospital_id")
	private Hospital hospital;

	//bi-directional many-to-one association to User
	@ManyToOne
	@JoinColumn(name="use_user_id")
	private User user1;

	//bi-directional many-to-one association to User
	@ManyToOne
	@JoinColumn(name="user_id")
	private User user2;//护士

	//bi-directional many-to-one association to OperationRecord
	@ManyToOne
	@JoinColumn(name="theater_id")
	private Theater theater;
 
	
	public Time getOperation_end_time() {
		return operation_end_time;
	}

	public void setOperation_end_time(Time operation_end_time) {
		this.operation_end_time = operation_end_time;
	}

	public Timestamp getOperation_start_time() {
		return operation_start_time;
	}

	public void setOperation_start_time(Timestamp operation_start_time) {
		this.operation_start_time = operation_start_time;
	}

	public OperationRecord() {
	}

	public int getOperationRecordId() {
		return this.operationRecordId;
	}

	public void setOperationRecordId(int operationRecordId) {
		this.operationRecordId = operationRecordId;
	}

	public Timestamp getDeathTime() {
		return this.deathTime;
	}

	public void setDeathTime(Timestamp deathTime) {
		this.deathTime = deathTime;
	}

	public String getOperationRecordDiagnose() {
		return this.operationRecordDiagnose;
	}

	public void setOperationRecordDiagnose(String operationRecordDiagnose) {
		this.operationRecordDiagnose = operationRecordDiagnose;
	}

 

	public String getOperationRecordState() {
		return this.operationRecordState;
	}

	public void setOperationRecordState(String operationRecordState) {
		this.operationRecordState = operationRecordState;
	}

	public Operation getOperation() {
		return operation;
	}

	public void setOperation(Operation operation) {
		this.operation = operation;
	}

	public Hospital getHospital() {
		return this.hospital;
	}

	public void setHospital(Hospital hospital) {
		this.hospital = hospital;
	}

	public User getUser1() {
		return this.user1;
	}

	public void setUser1(User user1) {
		this.user1 = user1;
	}

	public User getUser2() {
		return this.user2;
	}

	public void setUser2(User user2) {
		this.user2 = user2;
	}
 

	public Theater getTheater() {
		return theater;
	}

	public void setTheater(Theater theater) {
		this.theater = theater;
	}


}